#include "ScenesWidget.h"
#include "ComDialog.h"
#include "SceneGroup.h"
#include "SceneTypes.h"
CScenesWidget::CScenesWidget(void)
{
	setAllowedAreas(Qt::BottomDockWidgetArea);
	//setFeatures(QDockWidget::NoDockWidgetFeatures);
	setFixedHeight(150);
	initWindow();
}


CScenesWidget::~CScenesWidget(void)
{
}

void CScenesWidget::initWindow()
{
	m_pSceneGroup = new CSceneGroup(this);
	m_pSceneGroup->setGeometry(0, 20, width()-250, 130);

	m_sceneType = new CSceneTypes(this);
	m_sceneType->setGeometry(width()-250, 20, 120, 130);

	m_pColorPanel = new CColorWidget(this);
	m_pColorPanel->setGeometry(width()-130, 20, 130, 130);
}

void CScenesWidget::resizeEvent( QResizeEvent * )
{
	m_pSceneGroup->resize(width()-250, 130);
	m_sceneType->move(width()-250, 20);
	m_pColorPanel->move(width()-130, 20);
}
